package com.lihui.removestr;

import java.util.Scanner;

/**
 * 删除公共字符串
 *
 * @author wileda
 * @date 2022/11/20  19:38
 */
public class RemoveStr {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while(sc.hasNextLine()){
            String str1 = sc.nextLine();
            String str2 = sc.nextLine();
            System.out.println(remove(str1, str2));
        }
    }

    private static String remove(String str1, String str2) {
        String ans = "";
        int len1 = str1.length();
        int len2 = str2.length();
        for (int i = 0; i < len1; i++) {
            int j = 0;
            boolean temp = true;
            while(j < len2){
                if(str1.charAt(i) == str2.charAt(j)){
                temp = false;
                break;
                }
                j++;
            }
            if(temp == true){
                ans += str1.charAt(i);
            }
        }
        return ans;
    }



}
